package com.jumi.microservice.dto.taobao;

import com.jumi.microservice.common.page.PageDomain;
import com.jumi.microservice.constant.taobao.MaterialEnum;
import io.swagger.annotations.ApiModelProperty;

import java.util.Objects;

/**
 * @author Dirk
 * @Date 2021-01-08 13:48
 */
public class MaterialRequest extends PageDomain {
    private static final long serialVersionUID = -2219439079938850747L;

    @ApiModelProperty("物料ID枚举，选品库 FAVORITES, " +
            "实时热销榜(综合) HOT_SALE, 实时热销榜(大服饰) HOT_SALE_CLOTHES, 实时热销榜(大快消) HOT_SALE_FMCG, 实时热销榜(电器美家) HOT_SALE_ELECTRICAL_APPLIANCES, " +
            "高佣榜(综合) HIGH_COMMISSION, 高佣榜(鞋包配饰) HIGH_COMMISSION_SHOES_BAG, 高佣榜(母婴) HIGH_COMMISSION_MOTHER_BABY, 高佣榜(女装) HIGH_COMMISSION_WOMAN_DRESS, 高佣榜(美妆个护) HIGH_COMMISSION_COSMETIC, 高佣榜(食品) HIGH_COMMISSION_FOOD, 高佣榜(家居家装) HIGH_COMMISSION_FURNITURE, 高佣榜(男装) HIGH_COMMISSION_MAN_DRESS, 高佣榜(运动户外) HIGH_COMMISSION_OUTDOORS, 高佣榜(数码家电) HIGH_COMMISSION_DIGITAL, 高佣榜(内衣) HIGH_COMMISSION_UNDERWEAR, " +
            "猜你喜欢 GUESS_YOU_LIKE")
    private MaterialEnum materialEnum;

    @ApiModelProperty(value = "选品库投放id, 物料枚举为选品库时必填")
    private String favoritesId;

    public MaterialEnum getMaterialEnum() {
        return materialEnum;
    }

    public void setMaterialEnum(MaterialEnum materialEnum) {
        this.materialEnum = materialEnum;
    }

    public String getFavoritesId() {
        return favoritesId;
    }

    public void setFavoritesId(String favoritesId) {
        this.favoritesId = favoritesId;
    }

    @Override
    public boolean equals(Object o) {
        if (this == o) {
            return true;
        }
        if (o == null || getClass() != o.getClass()) {
            return false;
        }
        MaterialRequest that = (MaterialRequest) o;
        return materialEnum == that.materialEnum && Objects.equals(favoritesId, that.favoritesId);
    }

    @Override
    public int hashCode() {
        return Objects.hash(materialEnum, favoritesId);
    }
}
